In recent years, in a large-scale network as represented by Internet, to solve the problem of concentration of work load to one server terminal, there has been used the load distributing technology in which a plurality of server terminals are prepared in a server accessed from many client terminals so that the plurality of server terminals seem to function as one unit of server terminal to each client terminal.
This load distributing technology is a technology which reduces a work load on one unit of server terminal by distributing the access from client terminals to the plurality of server terminals. Accordingly, in the load distributing technology, when access is made from a client terminal, in order to improve the network efficiency it is important to route the access to a server terminal having the lowest load and shortest distance from the client terminal having made the access.
FIG. 9 shows the configuration of a conventional type of relaying apparatus for use in a network system. As shown this figure, an external network 1 is a large-scale network for data communications between a plurality of computers located at physically remote sites from each other. An example of this network is the Internet.
A network satisfying the following conditions can be classified as the Internet described above.
(1) The computer network has a communication protocol called TCP/IP (Transmission Control Protocol/Internet Protocol) installed therein.
(2) The computer network is connected to a global network comprising several major networks.
The protocols that can be used as the TCP/IP described above are the TCP and UDP (User Datagram Protocol) protocols defined in the fourth layer (transport layer) of the OSI (Open Systems interconnection). A feature of the TCP consists in that reliable data communications (transfer) can be carried out. In other words, the reliability of a communication path is maintained from the start to the end of the communication for enabling normal communication control, detection of an error and restoration from the error.
In contrast to the fact that the TCP provides a connection type of service for insuring reliability, the UDP is so-called a connection-less type of data transfer protocol for realization of high speed processing. In UDP such operations as confirmation of a response to improvement of reliability or sequence adjustment of received data transmitted through different routes in a network are not carried out.
A router 2 is connected to an external network 1, and obtains an IP address from an input IP packet and applies this IP packet to a routing table to execute a relay operation for transferring the IP packet for a router as a destination for transfer or a terminal (not shown herein). This relaying operation by the router 2 is called as routing (selection of a communication path). This IP address is assigned to a router as a destination for transfer or a terminal. The routing table is a table that shows a relation between a plurality of IP addresses and destinations for transfer corresponding to the IP addresses respectively.
A cluster network 3 is connected to the router 2 and accommodates therein a client terminal 41, client terminal 42, and a client-side DNS server 5. The client terminal 41 and client terminal 42 are the terminals provided in the client (user) side for requesting a service to a server terminal 7, a server terminal 9, and a server terminal 12 by sending the IP packet via the cluster network 3 to the router 2. The client-side DNS server 5 is a server for realization of the DNS (Domain Name System) which is one of Internet standards, and is connected to the cluster network 3.
The DNS will be explained in detail below. The IP address is used as explained above for identifying a terminal. However, this IP address comprises a combination of figures, so that it is very difficult for a user to remember the IP address. In order to solve this problem, a domain name (name space) is assigned to each terminal as an ID name which is easy for users to understand. The DNS is a system that manages a correspondence between domain names and IP addresses and returns an IP address in response to an inquiry with a domain name from the terminals (client terminal 41 and client terminal 42) Thus, the client side DNS server 5 is a device that realizes the DNS and is a local DNS server against the client terminal 41 and client terminal 42.
A router 6 is connected between the external network 1 and a server terminal 7, and has a routing function like that of the router 2 described above. This server terminal 7 is provided in the side of a service provider, and provides a service to the client terminal 41 and client terminal 41 in response to a request from the client terminal 41 and client terminal 42.
The router 8 is connected between the external network 1 and a server terminal 9, and has a routing function like that of the router 2. The server terminal 9 is a terminal for providing a service to the client terminal 41 and client terminal 42 in response to a request from the client terminal 41 and client terminal 42.
A router 10 is connected between the external network 1 and a cluster network 11, and has a routing function like that of the router 2. A server terminal 12 is connected to this cluster network 11. The server terminal 12 is a terminal for providing, like the server terminal 7 described above, a service to the client terminal 41 and client terminal 42 in response to a request from the client terminal 41 and client terminal 42.
The server terminals 7, 9, and 12 are provided at physically different positions. Accordingly, distance between each of the server terminals 7, 9, and 12 and the client terminal 41 or client terminal 42 (client-side DNS device 5) is different. Further, the server terminal 7, server terminal 9, and server terminal 12 functions like one unit of server terminal when viewed from the client terminal 41 or client terminal 42. Further, one domain name (described as a representative domain name) is assigned to all of the server terminal 7, server terminal 9, and server terminal 12 with different IP addresses assigned to the terminals respectively.
Namely in this case, a plurality of IP addresses are registered with one domain name, and when the client terminal 41 and client terminal 42 access with one domain name, any one of the server terminal 7, server terminal 9, and server terminal 12 can be accessed. Namely, the server terminal 7, server terminal 9, and server terminal 12 form one virtual server terminal specified by a representative domain name, and the client terminal 41 and client terminal 42 access a virtual IP address (representative domain name) of this virtual server terminal.
The configuration as described above in which a common domain name are assigned to the server terminal 7, server terminal 9, and server terminal 12 and any one of the server terminal 7, server terminal 9, and server terminal 12 can be accessed from the client terminal 41 and client terminal 42 is employed in order to distribute the work load as described above. Description is made later for the distribution of work load.
A DNS responding device 13 has a function as a DNS server like the client-side DNS server 5, and is positioned as an upper device to the client-side DNS server 5. Namely, the DNS responding device 13 has a function of responding to an inquiry on an IP address from the client-side DNS server 5. Further, the DNS responding device 13 puts the server terminal 7, server terminal 9, and server terminal 12 under control thereby, and when an inquiry is made for converting a representative domain name to an IP address, converts the representative domain name to an IP address of any one of the server terminal 7, server terminal 9, and server terminal 12, and reports it to the client-side DNS server 5. Namely, the DNS responding device 13 routes an access request from the client terminal 41 and client terminal 42 to any one of the server terminal 7, server terminal 9, and server terminal 12. This routing is the distribution of workload described above.
In the configuration described above, when access is made to a virtual server terminal having the virtual IP address described above, for instance, the client terminal 41 notices the client-side DNS server 5 of the representative domain name via the cluster network 3 to make an inquiry for a virtual IP address of the virtual server terminal to the client-side DNS server 5.
Thus the client-side DNS server 5 makes an enquiry for the virtual IP address to the DNS responding device 13 through the cluster network 3, router 2, external network 1, router 10 and cluster network 11. More specifically, the client-side DNS server 5 notices the DNS responding device 13 of the representative domain name.
Assuming herein that the server terminal 7 is a first server terminal, the server terminal 9 is a second server terminal, and server terminal 12 is a third server terminal, the DNS responding device 13 at first converts the reported representative domain name to an IP address of the first server terminal 7. The DNS responding device 13 then reports the IP address of the server terminal 7 via the cluster network 11, router 10, external network 1 and router 2 to the client-side DNS server 5. In response to this action, the client-side DNS server 5 reports the IP address of the server terminal 7 to the client terminal 41 through the cluster network 3.
The client terminal 41 that has received the IP address sends an IP packet including the IP address of the server terminal 7 via the cluster network 3 to the router 2. Thus, the IP packet is routed by the router 2, passes through the external network 1 and is further routed by the router 6, and arrives at the server terminal 7. As a result, connection between the client terminal 41 and server terminal 7 is established and the server terminal 7 provides a service requested by the client terminal 41.
In reality, although not shown, a plurality of routers are present within the external network and the IP packet is routed by and transferred through these routers.
When the representative domain name is reported by the client terminal 41 via the cluster network 3 to the client-side DNS server 5, the client-side DNS server 5 makes an inquiry of the virtual server terminal via the router 2, external network 1, router 10, and cluster network 11 to the DNS responding device 13.
The NDS responding device 13 then converts the reported representative domain name to an IP address of the second server terminal 9. The responding device 13 reports the IP address of the server terminal 9 via the cluster network 11, router 10, external network 1 and router 2 to the client-side DNS server 5. The client-side DNS server 5 reports the IP address of the server 9 via the cluster network 3 to the client terminal 42. The client terminal 42 having received the IP address sends an IP packet including the IP address of the server terminal 9 via the cluster network to the router 2. After the IP packet is routed by the router 2, the IP packet passes through the external network and is further routed by the router 8, and arrives at the server terminal 9. As a result, a connection between the client terminal 42 and the server terminal 9 is established, and the server terminal 9 provides the service requested from the client terminal 42.
Each time the DNS responding device 13 receives an inquiry on an IP address, the DNS responding device 13 successively reports the IP address of the third server terminal 12, the IP address of the first server terminal 7, and the IP address of the second server terminal 9 to the client-side DNS server 5. In other words, each time the DNS responding device 13 receives an inquiry concerning an IP address, the DNS responding device 13 distributes work load by routing an access from the client terminal 41 (or the client terminal 42) to the server terminal 12 to server terminal 7 to server terminal 9 to server terminal 12 to . . . in this order.
In the relaying apparatus used in the network system based on the conventional technology, an access request (IP packet) is routed simply to server terminal 12 to the server terminal 9 to server terminal 7 to server terminal 12 to . . . in this order according to an order of inquiries on an IP address from the client terminal 41 (or client terminal 42).
However, in the above method the following problems occurs because a distance between the client terminal 41 (or the client terminal 42) and each of the server terminal 7, server terminal 9, or server terminal 12 is not taken into account at all.
For instance, when an access request (IP packet) from the client terminal 41 is routed to the server terminal 7, although the distance between the client terminal 41 and the server terminal 7 is longer than the distance between the client terminal 4 and server terminal 9, routing to the server terminal 9 connectable to the client terminal 41 through the shortest route can not be carried out. Accordingly, in this case, the client terminal 41 having accessed the server terminal 7 is requires a longer access time than that in accessing the server terminal 9. It is not preferable when viewed from a view point of efficiency in load distribution or network efficiency.
In order to solve this problem, in the relaying apparatus for use in a network system based on the conventional technology, in routing an access request (IP packet), a distance between each of the server terminal 7, server terminal 9, and server terminal 12 and the client terminal 4 is estimated from a number of hops and this distance is taken into account. The number of hops is a number of routers through which an IP packet having been transmitted from a transmission source (for instance, client terminal 41) passes before it reaches a final destination (for instance, server terminal 7).
More specifically, when, for instance, the client terminal 41 issues a request for access and a representative domain name is reported from the client terminal 41 to the client-side DNS server 5, the client-side DNS server 5 reports the representative domain name via the cluster network 13, router 2, external network 1, router 10, and cluster network 11, like in the operation described above, to the DNS responding device 13.
In response to the above action, at first the DNS responding device 13 estimate a distance between the client terminal 41 and the server terminal 7 (described as a first distance hereinafter) according to a number of hops between the client terminal having issued the access request (client terminal 41) and the server terminal 7. The DNS responding device 13 then computes a distance between the client terminal 41 and the server terminal 9 (described as a second distance hereinafter) according to a number of hops between the client terminal 41 and the server terminal 9.
Finally, the DNS responding device 13 computes a distance between the client terminal 41 and the server terminal 12 (described as a third distance hereinafter) according to a number of hops between the client terminal 41 and the server terminal 12. It should be noted that, in the DNS responding device 13, the first, second, and third distances are stored in a database. When estimation of the first, second, and third distances is finished, the DNS responding device 13 selects one of the first, second, and third distances which is estimated as the shortest one. In this case, assuming that the second distance is estimated as the shortest one, the DNS responding device 13 reports the IP address of the server terminal 9 corresponding to this second distance via the cluster network 11, router 10, external network 1, router 2, and cluster network 3 to the client-side DNS server 5.
After an IP address of the server terminal 9 is reported from the client-side DNS server 5 via the cluster network 3 to the client terminal 41 the client terminal 41 having received this IP address accesses the server terminal 9 via the cluster network 3, router 2, external network 1, and router 8, and receives a service from the server terminal 9. Namely, in this case, the server terminal 9 estimated as the nearest one is routed to the client terminal 41.
As described above, in a relaying apparatus for use in a network system based on the conventional technology, first, second, and third distances between a client terminal (for instance, client terminal 41) and server terminals (the server terminal 7, server terminal 9, and server terminal 12) are estimated according to a number of hops between the client terminal and each of the server terminal 7, server terminal 9, and server terminal 12, and a service request from the client terminal (IP packet) is routed to a server terminal estimated as the nearest one for distribution of work load.
However, as well known, the number of hops is not always proportional to the distance. Namely, in a case where a number of routers are present in a small-scale network, the number of hops are large, but the actual distance is short because the network scale is small. In this case, the DNS responding device 13 estimates a distance which is longer than the actual one because of the large number of hops. Namely, an error between a distance estimated by the DNS responding device 12 and the actual distance is very large.
In the relaying apparatus for use in a network system based on the conventional technology, thus, a service request (IP packet) is routed according to only a number of hops as a basis for estimation of a distance including a very large estimation error. Therefore, some times the work load can not be distributed in an optimal form.
Further, even when a server terminal to which a service request (IP packet) is routed is in a high work load state and actually can not accept a request for service, routing is made only according to the estimated distance.
In the case as described above, as a client terminal having acquired an IP address of the server terminal in the high work load state can not receive a service from the server terminal, so that some time there may occur a state in which the client terminal can not receive a service unless re-acquiring an IP address of another server terminal in a low load state.
Thus, sometimes there occurs an unreasonable state that, even though there is a server terminal in a low work load state, a service request (IP packet) is routed to a server terminal in a high load state, which is not desirable for distribution of work load. Namely in a relaying apparatus for use in a network system based on the conventional technology, sometimes when a service request (IP packet) is routed according to a reference not reflecting the actual state, optimal work load distribution can not be carried out.